from sqlalchemy import Column, BigInteger, ForeignKey, Integer
from base import Base

class SysUserRole(Base):
    __tablename__ = 'sys_user_roles'

    user_id = Column(BigInteger, ForeignKey('sys_users.id'), primary_key=True, comment='用户ID')
    role_id = Column(Integer, ForeignKey('sys_roles.id'), primary_key=True, comment='角色ID')

    def __repr__(self):
        return f"<SysUserRole(user_id={self.user_id}, role_id={self.role_id})>"
